Skip to content

bridge: report what the chip's IrqMask kept out - #26

Merged
A13xB0 merged 3 commits into
MeshBench:mainfrom
NomDeTom:bridge-irq-suppressed
Oct 14, 2026
Merged

A13xB0 merged 3 commits into
MeshBench:mainfrom
NomDeTom:bridge-irq-suppressed

Conversation

@NomDeTom

@NomDeTom NomDeTom commented Oct 13, 2026 •

Copy link
Copy Markdown
Contributor

This moves vendor/virtual-sx1262 from 2861950 to f2604d1, the merge of MeshBench/virtual-sx1262#2, which is where VirtualSX1262::irqSuppressed() arrives. f2604d1 has the same tree as 8fb9623, the head of that PR, so the builds under Verification below cover this pin.

What this changes

The radio stats record (kRadioStats) grows from 37 bytes to 47:

bytes field
0-36 unchanged
37-38 DIO1 mask (dio1Mask())
39-42 console baud rate: 0, since a native node's console is a socket
43-46 irqSuppressed(): IRQ events the firmware's IrqMask kept out of the status register

Bytes 37-42 follow the layout MeshBench already reads from emulated nodes, so the two writers send one shape. MeshBench reads the record by length; a host that predates bytes 37-46 ignores them. MeshBench/meshbench#745 reads bytes 43-46.

Verification

Pin moved to v1.3.3

vendor/virtual-sx1262 now points at f0261f3, tagged v1.3.3, rather than f2604d1. That adds MeshBench/virtual-sx1262#3 (HeaderValid waits for the preamble, the SFD and the header block) and MeshBench/virtual-sx1262#5 (a LoRa header raises HeaderValid alone). No ABI change. simple_repeater and companion_radio build against companion-v1.16.0 and companion-v1.17.0 at this pin.

#5 changes the figures under Verification: SyncWordValid is no longer counted against masks that leave it out, so the three-node link is expected to read 12 for 1.16 (PreambleDetected only) and 0 for 1.17, not 24 and 12. That is the per-frame count from virtual-sx1262's tests and has not been rerun end to end.

The radio stats record grows from 37 bytes to 47. Bytes 37-42 take the
emulator's tail so the two writers keep one shape: the DIO1 mask, then a
console rate of zero, since a native console is a socket rather than a UART.
Bytes 43-46 carry irqSuppressed(), the number of events the firmware's
IrqMask kept out of the chip's status register.

MeshBench reads the record by length, so a host that predates the field
keeps working with either size.

irqSuppressed() comes from MeshBench/virtual-sx1262#2; this does not build
against the chip at the current pin (2861950).
@NomDeTom
NomDeTom marked this pull request as ready for review October 13, 2026 02:51
@A13xB0

A13xB0 commented Oct 14, 2026

Copy link
Copy Markdown
Collaborator

bumping virtual radio after release

v1.3.3 adds, on top of f2604d1: HeaderValid waits for the preamble, the
SFD and the header block (MeshBench#3), and a LoRa header raises HeaderValid
alone (MeshBench#5), so a firmware whose mask correctly leaves SyncWordValid out
no longer counts every header as suppressed. No ABI change.
@A13xB0
A13xB0 merged commit c9f5e54 into MeshBench:main Oct 14, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants